<?php
/**
 * Copyright 2011  SURFfoundation
 * 
 * This file is part of ESCAPE.
 * 
 * ESCAPE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * ESCAPE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with ESCAPE.  If not, see <http://www.gnu.org/licenses/>.
 * 
 * For more information:
 * http://escapesurf.wordpress.com/
 * http://www.surffoundation.nl/
 * 
 * Contact: d.vierkant@utwente.nl
 * 
 * @license http://www.gnu.org/licenses/gpl.html GNU GPLv3
 */
?>
<?php
/**
 * Entity
 * 
 * Represents an entity (document, person, etc), created by an entity factory.
 */
class entityresolution_Entity
{
	/**
	 * Subject URI. 
	 * @var string
	 */
	protected $subjectUri;
	
	/**
	 * Source RDF data.
	 * @var simplerdf_RdfDocument
	 */
	protected $sourceData;
	
	/**
	 * Expanded / normalized / filtered properties.
	 * @var array[int]entityresolution_Property
	 */
	protected $properties = array();
	
	/**
	 * Create a new entity instance.
	 * @param simplerdf_RdfDocument $sourceData source data
	 * @param string $subjectUri subject URI
	 */
	public function __construct($sourceData, $subjectUri)
	{
		$this->sourceData = $sourceData;
		$this->subjectUri = $subjectUri;
	}
	
	/**
	 * Get the subject URI.
	 * @return string subject URI
	 */
	public function getSubjectUri()
	{
		return $this->subjectUri;
	}
	
	/**
	 * Get the source data.
	 * @return simplerdf_RdfDocument source data
	 */
	public function getSourceData()
	{
		return $this->sourceData;
	}
	
	/**
	 * Get the properties.
	 * @return array[int]entityresolution_Property properties
	 */
	public function getProperties()
	{
		return $this->properties;
	}

	/**
	 * Set the properties.
	 * @param array[int]entityresolution_Property $properties properties
	 */
	public function setProperties($properties)
	{
		$this->properties = $properties;
	}
}